x11: Stop using gdk_surface_get_surface_type
authorMatthias Clasen <mclasen@redhat.com>
Sun, 8 Mar 2020 20:38:03 +0000 (13:38 -0700)
committerMatthias Clasen <mclasen@redhat.com>
Thu, 12 Mar 2020 19:30:10 +0000 (15:30 -0400)
gdk/x11/gdkdevicemanager-xi2.c
gdk/x11/gdkdisplay-x11.c

index 4699011a4232738897761f08e867cbdbb4e5551f..26adf003138f08a93af84306b316a54ff0a9eae7 100644 (file)
@@ -1865,7 +1865,7 @@ gdk_x11_device_manager_xi2_translate_event (GdkEventTranslator *translator,
 
         if (ev->evtype == XI_Enter &&
             xev->detail != XINotifyInferior && xev->mode != XINotifyPassiveUngrab &&
-           gdk_surface_get_surface_type (surface) == GDK_SURFACE_TOPLEVEL)
+            GDK_IS_TOPLEVEL (surface))
           {
             if (gdk_device_get_device_type (source_device) != GDK_DEVICE_TYPE_MASTER)
               _gdk_device_xi2_reset_scroll_valuators (GDK_X11_DEVICE_XI2 (source_device));
index 040844b247ac0901142bd567996407becebbf9cf..24e1636bb396ec4fe2962cabb5feb529f429a660 100644 (file)
@@ -375,7 +375,7 @@ do_net_wm_state_changes (GdkSurface *surface)
   GdkSurfaceState old_state, set, unset;
 
   if (GDK_SURFACE_DESTROYED (surface) ||
-      gdk_surface_get_surface_type (surface) != GDK_SURFACE_TOPLEVEL)
+      !GDK_IS_TOPLEVEL (surface))
     return;
 
   old_state = gdk_toplevel_get_state (GDK_TOPLEVEL (surface));